<template>
  <div>
    <div class="sidebar" >
      <a class="btn_create" @click="addPosition" >发布新职位</a>
      <el-menu
              :default-active="active"
              class="el-menu-vertical"
              background-color="#fafffd"
              text-color="#00000"
              active-text-color="#019875"
      >
        <el-menu-item index="1">
          <i class="el-icon-s-home"></i>
          <span slot="title" @click="index">首页</span>
        </el-menu-item>
        <el-submenu index="2">
          <template slot="title">
            <i class="el-icon-notebook-2"></i>
            <span>我收到的简历</span>
          </template>
          <el-menu-item-group>
            <el-menu-item index="1-1" @click="noResume()">未读简历</el-menu-item>
            <el-menu-item index="1-2" @click="oneResume()">待定简历</el-menu-item>
            <el-menu-item index="1-3" @click="twoResume()">已通知面试简历</el-menu-item>
            <el-menu-item index="1-4" @click="threeResume()">不合适简历</el-menu-item>
            <el-menu-item index="1-5" @click="fourResume()">面试通过简历</el-menu-item>
          </el-menu-item-group>
        </el-submenu>
        <el-submenu index="3">
          <template slot="title">
            <i class="el-icon-setting"></i>
            <span>我发布的职位</span>
          </template>
          <el-menu-item-group>
            <el-menu-item index="1-6" @click="OpenPosition()">有效(在招)职位</el-menu-item>
            <el-menu-item index="1-7" @click="noCheckedPosition()">待审核职位</el-menu-item>
            <el-menu-item index="1-8" @click="endPosition()">已下线职位</el-menu-item>
          </el-menu-item-group>
        </el-submenu>
        <el-menu-item index="3" @click="myCompany()">
          <i class="el-icon-office-building"></i>
          <span slot="title" >隶属公司</span>
        </el-menu-item>
      </el-menu>
    </div>
  </div>
</template>

<script>
  export default {
    data() {
      return {
        active: "1"
      }
    },
    methods: {
      addPosition(){
        this.$router.push("/hrWork/addPosition")
      },
      index() {
        this.$router.push("/main")
      },
      noResume() {
        this.$router.push("/hrWork/noResume")
      },
      oneResume() {
        this.$router.push("/hrWork/oneResume")
      },
      twoResume() {
        this.$router.push("/hrWork/twoResume")
      },
      threeResume(){
        this.$router.push("/hrWork/threeResume")
      },
      OpenPosition() {
        this.$router.push("/hrWork/openPosition")
      },
      noCheckedPosition(){
        this.$router.push("/hrWork/noCheckedPosition")
      },
      endPosition(){
        this.$router.push("/hrWork/endPosition")
      },
      myCompany(){
        this.$router.push("/hrWork/myCompany")
      },
      fourResume(){
        this.$router.push("/hrWork/fourResume")
      }
    }
  }
</script>

<style scoped>
  .el-menu-vertical {
    min-height: 600px;
  }

  .sidebar .btn_create {
    display: block;
    height: 45px;
    line-height: 45px;
    font-size: 18px;
    color: #fff;
    background: #91cebe url(img/icon_add.png) 45px center no-repeat;
    padding-left: 70px;
    -webkit-border-radius: 5px;
    -moz-border-radius: 5px;
    border-radius: 5px;
    margin-bottom: 15px;
    -webkit-transition: .2s;
    -moz-transition: .2s;
    transition: .2s
  }

  .sidebar .btn_create:hover {
    color: #fff;
    background-color: #019875
  }
</style>